/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package ucm;

import java.sql.SQLException;
import model.Flight;

/**
 * UCDeleteFlight
 *
 * Primary Actor: User.
 * Goal: Delete Flight.
 * Precondition: Connected to database. Flight exists on database. Manager is logged on.
 * Postcondition: Flight is deleted from database.
 *
 * @author Tobias Robinson
 */

public class UCDeleteFlight {

    public UCDeleteFlight() throws SQLException {
        run();
    }

    /**
     * 1. Actor selects Delete Flight.
     * 2. The system requests the actor to enter flight id.
     * 4. System verifies user input.
     * 5. System removes flight from database.
     * 6. System notifies actor flight has been deleted.
     */
    public void run() throws SQLException {
        Flight.loadDeleteFlightView();
    }
}
